package cn.stylefeng.guns.modular.commodity.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;


/**
 * @author allen
 * @date 2021/4/11 17:59
 * @version 1.0
 */

/**
 * 商品中心的商品信息基础表
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "commodity_goods")
public class CommodityGoodsEntity implements Serializable {
    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 类目ID
     */
    @TableField(value = "category_id")
    private Long categoryId;

    /**
     * 品牌ID
     */
    @TableField(value = "brand_id")
    private Long brandId;

    /**
     * SPU编号
     */
    @TableField(value = "code")
    private String code;

    /**
     * 商品名称
     */
    @TableField(value = "`name`")
    private String name;

    /**
     * 商品副名称
     */
    @TableField(value = "sub_name")
    private String subName;

    /**
     * 商品毛重，单位是g
     */
    @TableField(value = "gross_weight")
    private BigDecimal grossWeight;

    /**
     * 外包装长度，单位是cm
     */
    @TableField(value = "`length`")
    private BigDecimal length;

    /**
     * 外包装宽，单位是cm
     */
    @TableField(value = "width")
    private BigDecimal width;

    /**
     * 外包装高，单位是cm
     */
    @TableField(value = "height")
    private BigDecimal height;

    /**
     * 商品状态，1：待审核，2：待上架，3：审核未通过，4：已上架
     */
    @TableField(value = "`status`")
    private Integer status;

    /**
     * 服务保证
     */
    @TableField(value = "service_guarantees")
    private String serviceGuarantees;

    /**
     * 包装清单
     */
    @TableField(value = "package_list")
    private String packageList;

    /**
     * 运费模板ID
     */
    @TableField(value = "freight_template_id")
    private Long freightTemplateId;

    /**
     * 创建时间
     */
    @TableField(value = "gmt_create")
    private Date gmtCreate;

    /**
     * 更新时间
     */
    @TableField(value = "gmt_modified")
    private Date gmtModified;

    private static final long serialVersionUID = 1L;

    public static final String COL_ID = "id";

    public static final String COL_CATEGORY_ID = "category_id";

    public static final String COL_BRAND_ID = "brand_id";

    public static final String COL_CODE = "code";

    public static final String COL_NAME = "name";

    public static final String COL_SUB_NAME = "sub_name";

    public static final String COL_GROSS_WEIGHT = "gross_weight";

    public static final String COL_LENGTH = "length";

    public static final String COL_WIDTH = "width";

    public static final String COL_HEIGHT = "height";

    public static final String COL_STATUS = "status";

    public static final String COL_SERVICE_GUARANTEES = "service_guarantees";

    public static final String COL_PACKAGE_LIST = "package_list";

    public static final String COL_FREIGHT_TEMPLATE_ID = "freight_template_id";

    public static final String COL_GMT_CREATE = "gmt_create";

    public static final String COL_GMT_MODIFIED = "gmt_modified";
}